gcc: tighten condition for inhibit_libc=true#241206
Conversation
|
Why the change is needed? Does it fix anything? If it does then I suggest update the the description to say so. And maybe comment should hint why it's undesirable for other cases.
|
The situation described in the comment preceding `export inhibit_libc=true` does not match the conditional which follows it. Specifically, the comment says that this line is meant for "clang builds gcc" situations, yet it is enabled even when `!stdenv.cc.isClang`. This commit tightens the conditional to make it match the situation described in the comment.
Because what the comment says and what the code does are not the same. One of them must change. If you prefer to change the comment please submit a PR that explains why we
I think it's the other way around -- right now we have this
Yes, right now there's no way to not turn on
|
|
I'll remove myself from reviewers then. |
|
Rebased. |
|
This broke |
|
This also broke pkgsMusl.pkgsStatic.buildPackages.gccWithoutTargetLibc.cc, which is also required for pkgsMusl.nix: https://termbin.com/wf5i |

Description of changes
The situation described in the comment preceding
export inhibit_libc=truedoes not match the conditional which follows it. Specifically, the comment says that this line is meant for "clang builds gcc" situations, yet it is enabled even when!stdenv.cc.isClang.This commit tightens the conditional to make it match the situation described in the comment.
Needed for:
Things done
sandbox = trueset innix.conf? (See Nix manual)nix-shell -p nixpkgs-review --run "nixpkgs-review rev HEAD". Note: all changes have to be committed, also see nixpkgs-review usage./result/bin/)